Control device for controlling/regulating the operational sequences in a motor vehicle, and a method of starting such a control device

ABSTRACT

A control device ( 1 ) and a method for controlling/regulating the operational sequences in a motor vehicle, and a method for starting such a control device ( 1 ) are described. The essence of the present invention is to specify a program in a storage medium ( 4 ) of the control device ( 1 ) that is able to be executed independently of the frequency of the CPU ( 2 ), the program allowing the pulse frequency of the CPU ( 2 ) to be checked and measures for reprogramming the program to be initiated. During starting or operation of the control device ( 1 ), the frequency of the CPU ( 2 ) is checked first or the frequency of the CPU is compared to the frequency expected in the program. If necessary, measures for reprogramming the program are subsequently initiated.

BACKGROUND INFORMATION

[0001] The present invention is directed to a control device for controlling/regulating the operational sequences in a motor vehicle and a corresponding method, as well as a method of starting such a control device, and the respective particular computer programs on a storage medium according to the definitions of the species in the independent claims.

[0002] The functional sequences of control devices, used to control/regulate the operational sequences in a motor vehicle, are controlled from an input program using associated data which are input by the customer or the manufacturer of the control device. In its execution, this program is dependent upon the frequency of the CPU of the control device. One of the most common mistakes is to program a program that is not set up for the frequency of the CPU. Such a program is unable to run and may also no longer be reprogrammed since the routines for establishing the communication must be located in the frequency-dependent part of the software, thus making communication to the outside impossible. In such a case, the control-device program is no longer accessible from the outside and the control device thus will have to be returned to the manufacturer. For safety reasons, the execution of an incorrectly programmed program upon start-up of the vehicle must be prevented.

[0003] Therefore, it is the objective of the present invention to develop a control device and a method which prevents the execution of an incorrectly programmed program and allows a correction of the faulty program and the starting of such a control device.

[0004] This objective is achieved in accordance with the characterizing features of the respective independent claims.

[0005] Advantageous refinements of the present invention follow from the additional claims.

SUMMARY OF THE INVENTION

[0006] The present invention starts out from a control device and a method of controlling/regulating the operational sequences in a motor vehicle having a CPU with a predefined pulse frequency and a storage medium. The storage medium includes a frequency-dependent program. Frequency-dependent means that the program is executable as a function of the pulse frequency of the CPU. The control device according to the present invention is distinguished in that the storage medium is additionally provided with a frequency-independent program, which allows a check of the pulse frequency of the CPU and is able to initiate measures to reprogram the program.

[0007] Furthermore, the present invention in each case also relates to a computer program on a storage medium which, upon execution on a computer, especially a control device, executes a method of controlling/regulating operational sequences according to the present invention or a method of starting a control device according to the present invention. The computer programs may either be executed on a control device according to the present invention or on an external programming device. Both possibilities may be subsumed under the heading of being executed on a computer.

[0008] Proceeding in accordance with the independent claims ensures that an outbound communication is possible even when a program has been programmed incorrectly. Prior to executing the frequency-dependent program, the frequency-independent program checks whether its execution is possible, i.e., whether the expected frequency of the CPU matches the frequency provided for in the program. If this is the case, the execution of the program continues. Otherwise, the frequency-independent program initiates a measure to reprogram the incorrectly programmed program.

[0009] In this way, it is ensured that an incorrectly programmed program will not be executed and that the program is able to be corrected.

[0010] The storage medium may be, for instance, a hard disk, an EPROM, a flash-EPROM etc., but also a mobile storage medium such as a diskette or a CD-ROM.

[0011] Data relating to the pulse frequency of the CPU are preferably stored in a nonvolatile memory, especially an EPROM or ROM, or may be detected by this nonvolatile memory and read out from it for checking. This may involve the storage medium and also an additional storage means.

[0012] In the method according to the present invention of starting a control device, the pulse frequency of the CPU is first determined using a routine in the frequency-independent program and/or is read out from the nonvolatile memory. On the basis of the ascertained pulse frequency, it is checked whether the program has been programmed correctly. If the program has been programmed incorrectly, measures are initiated to reprogram it. In the case of a correctly programmed program, or following its reprogramming, the execution begins.

[0013] The method may be carried out prior to the first starting of the control device. However, it is also conceivable that it is reexecuted upon every start.

[0014] It is advantageous if data relating to the pulse frequency of the CPU is stored in a non-erasable memory, such as a ROM. The routine for determining the pulse frequency reads in this data via a first interface between the program and ROM.

[0015] Following a check of the determined pulse frequency, the routine preferably outputs a Boolean value which indicates whether or not the program has been programmed correctly. The Boolean value is forwarded to the program via a second interface.

[0016] The routine for determining the CPU frequency has two interfaces; one of these is the interface with the ROM via which the data relating to the actual frequency of the utilized CPU is collected. The second interface represents the connection to the program to which the expected CPU frequency pulse stipulated in the program and also the result of the comparison, i.e., the Boolean value, have to be forwarded. The Boolean value is TRUE if the determined CPU frequency corresponds to the expected pulse frequency, i.e., the program frequency. Otherwise, the value is FALSE.

[0017] In this context, a tolerance range may advantageously be provided. Slight deviations between the expected pulse frequency, which is able to be determined from the frequency-dependent program, and the pulse frequency of the CPU, that is, deviations within a predefinable tolerance range that will not limit the performance reliability, may be allowed. Within the tolerance range for a frequency deviation, it is thus also possible that TRUE may expediently be output when using Boolean values.

[0018] The code of the routine is advantageously located in the same region as the initialization routines of the control program. In this way it is possible to ensure that the code is always available when the initialization routines are executed. If possible, the routine should be called at the beginning of the initialization. The further execution of the initialization will only be allowed if the diagnostics routine has returned the value TRUE. The reason for this early execution is that otherwise it may happen that registers have already been reconfigured in accordance with the program defaults, thereby interrupting the execution of the frequency-independent program. Consequently, there is also no reason to continue processing configuration data before exiting an incorrect program, or, in the case of a correct program, to execute such a functionality before checking the CPU frequency.

[0019] Further advantages and advantageous refinements result from the specification and the claims.

BRIEF DESCRIPTION OF THE DRAWING

[0020] The present invention is described in greater detail on the basis of the attached two drawings (FIGS. 1 and 2). The figures show:

[0021]FIG. 1 a control device 1 according to the present invention with a programming device 15 in a schematic representation;

[0022]FIG. 2 the sequence of the method according to the present invention.

DESCRIPTION OF THE EXEMPLARY EMBODIMENTS

[0023] Control device 1 has a CPU 2, a ROM 3, a storage medium 4 and an input/output unit 5. The various components are interconnected by a data bus 6. Storage medium 4 may be subdivided into two parts, namely a frequency-dependent and a frequency-independent part.

[0024] Storage medium 4 includes the frequency-dependent program as well as the frequency-independent program which is able to run independently of the pulse frequency of CPU 2 and checks the pulse frequency of CPU 2 prior to executing the program and, if necessary, initiates measures to reprogram the program. The data relating to the pulse frequency of CPU 2 is provided by ROM 3, for instance. Via input-output unit 5, which is of serial or parallel type, for example, control device 1 communicates with a control device or programming device 15. It should be mentioned that this programming device is represented purely schematically in FIG. 1, and means for assuring communication between control device 1 and control device or programming device 15 are not shown in detail. This external programming device, which may also be a common personal computer, is used to input programs and/or data, such as a new program version and/or data version. It is also conceivable to use additional media and/or devices as external programming device. The shown control device 1 is used to control operating sequences, especially in a motor vehicle, for example, for a transmission control system, an engine control system, a brake control system (ABS, ASR, ESP etc.), a steering control system, a vehicle movement control and/or an adaptive cruise control (ACC) etc.

[0025]FIG. 2 shows the sequence of the method according to the present invention.

[0026] In a step 7 in FIG. 2, control device 1 (FIG. 1) is started up. Directly at the beginning, in step 8, the pulse frequency of CPU 2 is checked by reading out CPU-internal configuration registers. In addition, by a comparison to data stored in the frequency-dependent program, it is determined whether the driving program stored on storage medium 4 (FIG. 1) is set up for the pulse frequency of CPU 2 (FIG. 1). The data relating to the pulse frequency are provided by ROM 3 (FIG. 1). If the program has been programmed incorrectly, i.e., the frequency stored in the frequency-dependent program does not match the frequency determined by the ROM, measures for reprogramming the program are initiated in step 9. For this purpose, the execution of the control program is terminated and the sequencing control returned to the ROM. The sequencing control in the ROM allows the frequency-dependent control program to be reprogrammed. If the reprogramming has ended, or if a correctly programmed program was available from the beginning, the program is executed in step 10.

[0027] It is also conceivable to recheck the pulse frequency of CPU 2 (FIG. 1) once the program has been reprogrammed, or to check that the pulse frequency of the CPU and the expected frequency of the frequency-dependent program match, and only then begin with the execution of the program.

[0028] In accordance with the described method for starting the control device and for controlling/regulating operational sequences, especially in a motor vehicle, these methods are able to be implemented if corresponding computer programs are stored on a storage medium or data medium and these are executed on a computer, especially a control device.

[0029] The aforementioned storage means or data media with the corresponding computer program may be a hard disk, an EPROM, flash-EPROM etc., that is, an integrated storage means, but also a mobile storage medium, such as a diskette or a CD-ROM. If the computer program according to the method of the present invention is then executed on a computer, the methods are carried out in accordance with at least one of the method claims. In the process, the respective computer program as it relates to the exemplary embodiment may be executed on control device 1, on the one hand, and on programming device 15, on the other hand. A combined execution on both (1 and 15) is possible as well.

[0030] The independence from the CPU-frequency of the frequency-independent part or the frequency-independent program may also be achieved here in an additional embodiment by these having the ability of adapting to a multitude, or all possible, CPU-pulse frequencies. 

What is claimed is:
 1. A control device for controlling/regulating the operational sequences in a motor vehicle, comprising a CPU having a predefined pulse frequency; a storage means which includes a frequency-dependent program and/or data for controlling and/or regulating the operational sequences, wherein a frequency-independent program is provided in the storage means (4) which determines an expected pulse frequency from the frequency-dependent program and/or data, thereby allowing a comparison of the pulse frequency of the CPU (2) and the expected pulse frequency, the frequency-independent program being able to initiate measures for reprogramming the frequency-dependent program and/or data.
 2. The control unit as recited in claim 1, characterized by an additional storage means, in particular a ROM (3), in which data relating to the pulse frequency of the CPU (2) are stored.
 3. A method for starting a control device as recited in one of claims 1 or 2, in which the pulse frequency of the CPU (2) is first determined using a routine in the frequency-independent program, a check being carried out on the basis of the determined pulse frequency whether the program was programmed correctly, and in the case of an incorrectly programmed program, measures are initiated to reprogram the program, and, in the case of a correctly programmed program, its execution is begun.
 4. The method as recited in claim 3, characterized by storage means, especially a ROM (3), in which data relating to the pulse frequency of the CPU (2) are stored and the routine for determining the pulse frequency of the CPU (2) reads in these data via a first interface between the program and storage means, especially the ROM (3).
 5. The method as recited in claim 4, wherein, following a comparison of the pulse frequency of the CPU to an expected pulse frequency of the frequency-dependent program, the routine for determining the pulse frequency outputs a Boolean value as the result and provides it to the program via a second interface.
 6. A method for controlling/regulating the operational sequences in a motor vehicle using a frequency-dependent program based on the pulse frequency of a CPU, the pulse frequency of the CPU being determined and/or read out, the frequency-dependent program being stored on a first storage means, wherein a frequency-independent program is stored on the first or a second storage means, an expected pulse frequency of the frequency-dependent program being determined with the aid of the frequency-independent program and a comparison of the expected pulse frequency and the pulse frequency of the CPU being carried out, a reprogramming of the frequency-dependent program being able to be implemented as a function of the comparison.
 7. The method as recited in claim 6, wherein data relating to the pulse frequency of the CPU are stored on the second storage means, especially a ROM, and these are read out from there by the frequency-independent program or the pulse frequency of the CPU is determined there from these data.
 8. A computer program on a storage means for starting a control device as recited in claim 1, which is suited for executing a method as recited in one of claims 3 through 5 when it is executed on a computer, especially the control device or a programming device.
 9. A computer program for controlling/regulating of operational sequences in a vehicle in combination with a control device as recited in claim 1 on a storage means which is suitable for executing a method as recited in claim 6 or 7 when it is executed on a computer, especially a control device. 